/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package com.cxhd.pacs.model;

import com.jfinal.core.Controller;
import com.jfinal.plugin.activerecord.Model;
import java.util.Map;

/**
 *
 * @author Administrator
 */
public class Inhospital extends Model<Inhospital> {

    public boolean saveInhospital(Controller ctrl) {
        try {
            Map<String, String[]> map = ctrl.getParaMap();
            for (String key : map.keySet()) {
                set(key, ctrl.getPara("key"));
            }
            save();
            return true;
        } catch (Exception e) {
            e.printStackTrace();
            return false;
        }
    }

}
